package com.zuikaku.aop;

import org.aspectj.lang.JoinPoint;
import org.aspectj.lang.ProceedingJoinPoint;

public class LogAspect {

    public void beforeNotify(JoinPoint j){
        System.out.println("---前置通知---"+j.getSignature().getName());
    }


    public void afterNotify(JoinPoint j){
        System.out.println("---后置通知---"+j.getSignature().getName());
    }


    public void runningNotify(JoinPoint j){
        System.out.println("---运行通知---"+j.getSignature().getName());
    }


    public void exceptionNotify(JoinPoint j,Throwable e){
        System.out.println("---异常通知---"+j.getSignature().getName()+" 异常："+e.toString());
    }

}
